package com;

import java.util.ServiceLoader;

import com.service.Animal;

public class Test {
	public static void main(String[] args) {
		ServiceLoader<Animal> animalList = ServiceLoader.load(Animal.class);
		animalList.forEach((animal) -> {
			System.out.println(animal.getClass());
			System.out.println(animal.getName());
		});		
	}
}
